package com.burgeon.backend.SHOP.controller;


import com.burgeon.backend.SHOP.entity.AppLinkData;
import com.burgeon.backend.SHOP.service.AppLinkService;
import com.burgeon.backend.SHOP.service.SystemService;
import com.burgeon.backend.stsutil.ResponseResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.servlet.http.HttpSession;
import java.util.List;

@RequestMapping("shop/link")
@RestController
public class AppLinkController extends BaseController{
    @Autowired
    private AppLinkService appLinkService;

    @RequestMapping("data")
    public ResponseResult<List<AppLinkData>> Data(HttpSession session) {
        String token = session.getAttribute("token").toString();
        List<AppLinkData> data = appLinkService.getData(token);
        return new ResponseResult<List<AppLinkData>>(SUCCESS,data);
    }


}
